﻿using System;
using System.Collections.Generic;
using Xenta.Api;

namespace Xenta.Structs
{
    /// <summary>
    /// Represents the transformation info struct.
    /// </summary>
    public struct TransformInfo
    {
        #region Properties

        /// <summary>
        /// Gets or sets the transformation global-unique identifier.
        /// </summary>
        public Guid ID;

        /// <summary>
        /// Gets or sets the transformation properties.
        /// </summary>
        public IDictionary<String, String> Properties;

        #endregion

        #region Methods

        internal HandlerInfo ToHandlerInfo()
        {
            return new HandlerInfo
            {
                Guid = ID,
                Properties = Properties != null
                    ? new Dictionary<String, String>(Properties)
                    : null
            };
        }

        #endregion
    }
}
